package com.qf.artical.mapper;


import com.qf.artical.pojo.User;
import com.qf.artical.service.UserService;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

/**
 * @author
 */
public interface UserMapper {

    /**
     *添加
     * @param user
     */
    @Insert("Insert INTO user (id,name,desc,time )values(#{id},#{name},#{desc},#{time})")
    void AddUser(User user);


    /**
     * 根据名字查询
     * @param name
     * @return
     */
    @Select("SELECT * FROM user where name=#{name}")
    User findUserByName(String name);
}
